﻿using System;
using System.Drawing;

namespace Maze
{
    public enum SQ { O, W, S, C }

    public class Board
    {
        private SQ[,] squares;
        private Player player;
        private Enemy[] enemies;

        public Board(SQ[,] squares)
        {
            this.squares = squares;
        }

        public Player Player
        {
            get
            {
                return this.player;
            }
            set
            {
                this.player = value;
            }
        }

        public Enemy[] Enemies
        {
            get
            {
                return this.enemies;
            }
            set
            {
                this.enemies = value;
            }
        }

        public SQ this[int x, int y]
        {
            get
            {
                return this.squares[y, x];
            }
            set
            {
                this.squares[y, x] = value;
            }
        }

        public SQ this[Point square]
        {
            get
            {
                return this[square.X, square.Y];
            }
            set
            {
                this[square.X, square.Y] = value;
            }
        }

        public int Rows
        {
            get
            {
                return this.squares.GetLength(0);
            }
        }

        public int Columns
        {
            get
            {
                return this.squares.GetLength(1);
            }
        }
    }
}
